package com.blink.model.entity;

import com.blink.model.iUser;
import org.apache.commons.lang3.builder.ReflectionToStringBuilder;

/**
 * @Author liuzhao
 * @ClassName: User
 * @Description: 用户实体类
 * @Date 2015年7月10日 上午9:52:11
 */
public class User implements iUser {
    private String userNo;
    private String userName;
    private Integer age;
    private String sex;

    @Override
    public String getUserNo() {
        return userNo;
    }

    public void setUserNo(String userNo) {
        this.userNo = userNo;
    }

    @Override
    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    @Override
    public Integer getAge() {
        return age;
    }

    public void setAge(Integer age) {
        this.age = age;
    }

    @Override
    public String getSex() {
        return sex;
    }

    public void setSex(String sex) {
        this.sex = sex;
    }

    public User() {
    }

    private User(String userNo, String userName, Integer age, String sex) {
        this.userNo = userNo;
        this.userName = userName;
        this.age = age;
        this.sex = sex;
    }

    public static User create(String userNo, String userName, Integer age, String sex) {
        return new User(userNo, userName, age, sex);
    }

    @Override
    public String toString() {
        return ReflectionToStringBuilder.toString(this);
    }
}
